Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update tokyonight themes #9099

Merged

Conversation

UntimelyCreation
Copy link
Contributor

Hey there!

After seeing some auto-generated Helix themes by folke in his neovim tokyonight repository, I decided to update Helix's themes accordingly.

I carefully went through everything and landed on a clean, best-of-both-worlds result which I think is a nice improvement from the previous versions. I've added the two missing themes, tokyonight_moon and tokyonight_day, and updated my email address.

Here are some screenshots below.

20231215_164357
20231215_164414
20231215_164426
20231215_164441

If you see any mistake or improvement to make, feel free to contact me or make any changes!

Cheers!

Copy link
Member

@the-mikedavis the-mikedavis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could we keep tokyonight_night as tokyonight? This would be a breaking change for anyone using theme = "tokyonight" in their config

@UntimelyCreation
Copy link
Contributor Author

Very fair point, I just changed it back!

@the-mikedavis the-mikedavis added A-theme Area: Theme and appearence related S-waiting-on-review Status: Awaiting review from a maintainer. labels Dec 18, 2023
@archseer
Copy link
Member

What were the changes from the upstreamed theme and could we merge some of the improvements?

\cc @Finistere who has contributed this upstream (folke/tokyonight.nvim#409 -- wish we knew about it sooner!)

@UntimelyCreation
Copy link
Contributor Author

UntimelyCreation commented Dec 19, 2023

What I did was use the upstream themes as a new baseline, and manually edit the file into something cleaner, mostly putting all colors into variables and dividing the file into sections in the spirit of the documentation and my previous themes.
I then corrected and added a few elements by hand to make it look nicer, as the upstream auto-generation seemed to miss a few things, such as the ruler, indent guides, etc

Copy link
Contributor

@SoraTenshi SoraTenshi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Generally this seems to refresh the theme quite a bit.
I added some comments, as i daily drive tokyo-night-storm and want to know what's going on with the theme i love so much.

"ui.text.info" = { bg = "bg-menu", fg = "fg" }
"ui.virtual.ruler" = { bg = "fg-gutter" }
"ui.virtual.whitespace" = { fg = "fg-gutter" }
"ui.virtual.inlay-hint" = { bg = "bg-inlay", fg = "teal" }
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As someone that uses tokyo-night-storm and inlay-hints, i'd be relatively unhappy in having so strong colours for inlay-hints they should imo be as unnoticeable as possible. That's why i also made them have no bg as well as its fg-color to be the same as comments (which imo is the best way to handle it).

Any insight as to why make them so bold in colour?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I just think of it the other way around. I like to make them stand out a bit from the base code as it is not part of it and is useful hinting, so I kept the upstream colors.
I also completely understand your point of view, and would be happy to leave them as they were before, which is "ui.virtual.inlay-hint" = { fg = "comment" } as you described.

Copy link
Contributor

@SoraTenshi SoraTenshi Dec 20, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wouldn't mind giving your idea a test-drive, there's always the ability to revert it anyway in the future :)
Maybe i would base the decision on whether it should be colorful / plain based on how it is handled in other themes? (i can't quite tell yet as i am using my own fork, i don't know what the current status quo is)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

After looking at the other themes, the inlay hints do seem to follow the more discreet approach, though there are both.
I'd say it's just a matter of personal preference.
As you seem OK with the change, let's leave it like this for now. There's always the option to change it back afterwards as you said!

"function.macro" = { fg = "cyan" }
"keyword" = { fg = "cyan", modifiers = ["italic"] }
"function.special" = { fg = "cyan" }
keyword = { fg = "purple", modifiers = ["italic"] }
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why change the normal keyword to purple?
Just a question, no particular opinion on it as of right now.

Copy link
Contributor Author

@UntimelyCreation UntimelyCreation Dec 20, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Coming from neovim, I try to stay as close as possible to folke's colors, as I intended when I first created the helix ones.
You can see this as a long due, small correction. I just didn't want to make a PR only for this, and thus waited for a more general update.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds good to me!

Copy link
Contributor

@SoraTenshi SoraTenshi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Generally i think i am OK with how things end up either way in terms of the inlay-hints.

@pascalkuthe pascalkuthe merged commit 154d9b6 into helix-editor:master Jan 8, 2024
6 checks passed
SoraTenshi pushed a commit to SoraTenshi/helix that referenced this pull request Jan 10, 2024
SoraTenshi pushed a commit to SoraTenshi/helix that referenced this pull request Jan 10, 2024
woojiq pushed a commit to woojiq/helix that referenced this pull request Jan 13, 2024
@UntimelyCreation UntimelyCreation deleted the tokyonight-update branch January 17, 2024 08:48
SoraTenshi pushed a commit to SoraTenshi/helix that referenced this pull request Jan 22, 2024
dgkf pushed a commit to dgkf/helix that referenced this pull request Jan 30, 2024
mtoohey31 pushed a commit to mtoohey31/helix that referenced this pull request Jun 2, 2024
Vulpesx pushed a commit to Vulpesx/helix that referenced this pull request Jun 7, 2024
smortime pushed a commit to smortime/helix that referenced this pull request Jul 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-theme Area: Theme and appearence related S-waiting-on-review Status: Awaiting review from a maintainer.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants